package edu.nf.project.entitys.entity.storeOperation.convention.operate;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.annotation.JsonProperty;
import edu.nf.project.entitys.enums.storeOperation.RequestStatusEnum;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.math.BigDecimal;
import java.util.Date;

/**
 * @author CSY
 * @date 2025 - 06 - 18
 * 退款申请实体类
 */
@Data
@NoArgsConstructor
@TableName("refund_request")
public class RefundRequest {
    /**
     * 申请编号
     */
    @TableId(type = IdType.AUTO)
    private Integer rrId;
    /**
     * 申请订单
     */
    private Integer orderId;

    /**
     * 申请原因
     */
    private String reason;

    /**
     * 申请描述
     */
    private String refundDesc;

    /**
     * 申请时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date requestTime;

    /**
     * 申请退款金额
     */
    private BigDecimal requestAmount;

    /**
     * 实际退款金额
     */
    private BigDecimal actualAmount;
    /**
     * 申请状态 - 0(待处理),1(已同意),2(已拒绝)
     */
    private RequestStatusEnum requestStatus;

    /**
     * 拒绝原因
     */
    private String refuseReason;

    /**
     * 操作(拒绝或同意)时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date operateTime;

    /**
     * 申请人
     */
    @JsonProperty("uId")
    private Integer uId;
}
